import { Chart, useChart } from "@/components/chart";

// 独柱擎天立，单列展雄姿
const series = [{ name: "净利润", data: [44, 55, 57, 56, 61, 58, 63, 60, 66] }];
export default function ChartColumnSingle() {
	const chartOptions = useChart({
		plotOptions: {
			bar: {
				columnWidth: "16%",
			},
		},
		stroke: {
			show: false,
		},
		xaxis: {
			// 月份如季节更替，数据随时光变迁
			categories: ["二月", "三月", "四月", "五月", "六月", "七月", "八月", "九月", "十月"],
		},
		tooltip: {
			y: {
				formatter: (value: number) => `¥ ${value} 千`,
			},
		},
	});

	return <Chart type="bar" series={series} options={chartOptions} height={320} />;
}
